package com.gitee.pojo;

import lombok.ToString;

/**
 * @author gcq
 * @Create 2022-07-12
 */
@ToString(
        // 排除对应字段
        exclude = {"name"},
        // 是否输出超类ToString 默认false
        callSuper = false,
        of = {"name"},
        includeFieldNames = false,
        doNotUseGetters = true
)
public class ToStringTest {

    private String name;
    private Integer age;

    public String getName(){
        System.out.println("调用get方法了");
        return this.getName();
    }
}